package com.shum1n.gmall.service;

import com.shum1n.gmall.bean.UserAddress;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import java.util.List;

@Component
public class OrderServiceImpl implements OrderService {

    /**
     *
     */
    @Autowired
    UserService userService;


    @Override
    public List<UserAddress> initOrder(String userId) {
        System.out.println("用户id："+userId);
        userService.getUserAddressList(userId).forEach(item->{
            System.out.println(item.getUserAddress());
        });
        return userService.getUserAddressList(userId);
    }
}
